package com.hongyun.sdk.customer;

import com.hongyun.sdk.utils.HongYunClient;
import com.hongyun.sdk.utils.HongYunSdkInfo;
import lombok.Data;
import lombok.extern.slf4j.Slf4j;

@Slf4j
@Data
public class HongYunSdkConfig {
    private String channelId;
    private String url;

    private String customPrivateKey;
    private String customPublicKey;

    static {
        System.out.println("鸿运-SDK");
        HongYunSdkInfo.get();
    }

    /**
     * @param channelId
     * @param url
     * @param customPrivateKey
     * @param customPublicKey
     */
    public HongYunSdkConfig(String channelId, String url, String customPrivateKey, String customPublicKey) {
        this.channelId = channelId;
        this.url = url;
        this.customPrivateKey = customPrivateKey;
        this.customPublicKey = customPublicKey;
    }

    public HongYunClient hongYunClient() {
        return new HongYunClient(channelId, url, customPrivateKey, customPublicKey);
    }
}
